find_package(yaml-cpp REQUIRED)
find_package(JNI REQUIRED)
find_package(fmt REQUIRED)

find_package(PkgConfig REQUIRED)
pkg_check_modules(dpdk REQUIRED IMPORTED_TARGET libdpdk)

add_library(KawausoGateway SHARED

        runtime/reactor.cc
        runtime/network_poller.cc

        net/ethernet.cc

        plugin/plugin_executor.cc

        util/options.cc
        util/logger.cc
        util/local_store.cc
        util/initializer.cc
        util/future.cc
        util/queue.cc
)

target_link_libraries(KawausoGateway PUBLIC
        yaml-cpp::yaml-cpp
        JNI::JVM
        rt
        fmt::fmt
        PkgConfig::dpdk
)

add_executable(KawausoGatewayApplication bootstrap.cc)
target_link_libraries(KawausoGatewayApplication KawausoGateway)